package com.jxc.jxc01.yk.entity;

import java.util.Objects;

/**
 * 销售
 */
public class Sales {
    //id
    public int id;
    //销售单号
    public int salesnumber;
    //销售人
    public String salesperson;
    //销售商品
    public String salesgoods;
    //商品种类
    public String variety;
    //客户
    public String salesname;
    //计量单位
    public String units;
    //销售数量
    public int salesvolume;
    //销售单价
    public double salesprice;
    //销售总价
    public double totalprice;
    //销售时间
    public String salestime;
    //状态
    public String condition;


    public Sales() {
    }

    public Sales(int id, int salesnumber, String salesperson, String salesgoods, String variety, String salesname, String units, int salesvolume, double salesprice, double totalprice, String salestime, String condition) {
        this.id = id;
        this.salesnumber = salesnumber;
        this.salesperson = salesperson;
        this.salesgoods = salesgoods;
        this.variety = variety;
        this.salesname = salesname;
        this.units = units;
        this.salesvolume = salesvolume;
        this.salesprice = salesprice;
        this.totalprice = totalprice;
        this.salestime = salestime;
        this.condition = condition;
    }

    /**
     * 获取
     * @return id
     */
    public int getId() {
        return id;
    }

    /**
     * 设置
     * @param id
     */
    public void setId(int id) {
        this.id = id;
    }

    /**
     * 获取
     * @return salesnumber
     */
    public int getSalesnumber() {
        return salesnumber;
    }

    /**
     * 设置
     * @param salesnumber
     */
    public void setSalesnumber(int salesnumber) {
        this.salesnumber = salesnumber;
    }

    /**
     * 获取
     * @return salesperson
     */
    public String getSalesperson() {
        return salesperson;
    }

    /**
     * 设置
     * @param salesperson
     */
    public void setSalesperson(String salesperson) {
        this.salesperson = salesperson;
    }

    /**
     * 获取
     * @return salesgoods
     */
    public String getSalesgoods() {
        return salesgoods;
    }

    /**
     * 设置
     * @param salesgoods
     */
    public void setSalesgoods(String salesgoods) {
        this.salesgoods = salesgoods;
    }

    /**
     * 获取
     * @return variety
     */
    public String getVariety() {
        return variety;
    }

    /**
     * 设置
     * @param variety
     */
    public void setVariety(String variety) {
        this.variety = variety;
    }

    /**
     * 获取
     * @return salesname
     */
    public String getSalesname() {
        return salesname;
    }

    /**
     * 设置
     * @param salesname
     */
    public void setSalesname(String salesname) {
        this.salesname = salesname;
    }

    /**
     * 获取
     * @return units
     */
    public String getUnits() {
        return units;
    }

    /**
     * 设置
     * @param units
     */
    public void setUnits(String units) {
        this.units = units;
    }

    /**
     * 获取
     * @return salesvolume
     */
    public int getSalesvolume() {
        return salesvolume;
    }

    /**
     * 设置
     * @param salesvolume
     */
    public void setSalesvolume(int salesvolume) {
        this.salesvolume = salesvolume;
    }

    /**
     * 获取
     * @return salesprice
     */
    public double getSalesprice() {
        return salesprice;
    }

    /**
     * 设置
     * @param salesprice
     */
    public void setSalesprice(double salesprice) {
        this.salesprice = salesprice;
    }

    /**
     * 获取
     * @return totalprice
     */
    public double getTotalprice() {
        return totalprice;
    }

    /**
     * 设置
     * @param totalprice
     */
    public void setTotalprice(double totalprice) {
        this.totalprice = totalprice;
    }

    /**
     * 获取
     * @return salestime
     */
    public String getSalestime() {
        return salestime;
    }

    /**
     * 设置
     * @param salestime
     */
    public void setSalestime(String salestime) {
        this.salestime = salestime;
    }

    /**
     * 获取
     * @return condition
     */
    public String getCondition() {
        return condition;
    }

    /**
     * 设置
     * @param condition
     */
    public void setCondition(String condition) {
        this.condition = condition;
    }

    public String toString() {
        return "Sales{id = " + id + ", salesnumber = " + salesnumber + ", salesperson = " + salesperson + ", salesgoods = " + salesgoods + ", variety = " + variety + ", salesname = " + salesname + ", units = " + units + ", salesvolume = " + salesvolume + ", salesprice = " + salesprice + ", totalprice = " + totalprice + ", salestime = " + salestime + ", condition = " + condition + "}";
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        Sales sales = (Sales) o;
        return id == sales.id && salesnumber == sales.salesnumber && salesperson == sales.salesperson && salesvolume == sales.salesvolume && Double.compare(sales.salesprice, salesprice) == 0 && Objects.equals(salesgoods, sales.salesgoods) && Objects.equals(variety, sales.variety) && Objects.equals(salesname, sales.salesname) && Objects.equals(units, sales.units) && Objects.equals(totalprice, sales.totalprice) && Objects.equals(salestime, sales.salestime) && Objects.equals(condition, sales.condition);
    }

    @Override
    public int hashCode() {
        return Objects.hash(id, salesnumber, salesperson, salesgoods, variety, salesname, units, salesvolume, salesprice, totalprice, salestime, condition);
    }
}
